package com.example.csupermaket.pojo.dto;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.time.LocalDateTime;

@Data
public class ProductAddNewDTO implements Serializable {

    @ApiModelProperty(value = "商品名称", required = true)
    @NotNull(message = "必须提交商品名称")
    private String pName;

    @ApiModelProperty(value = "商品价格", required = true)
    @NotNull(message = "必须提交商品价格")
    private Double price;

    @ApiModelProperty(value = "库存", required = true)
    @NotNull(message = "必须提交库存")
    private Integer inventory;

    @ApiModelProperty(value = "商品详情介绍")
    private String introduction;

    @ApiModelProperty(value = "商品分类", required = true)
    @NotNull(message = "必须提交商品分类")
    private String cid;

    @ApiModelProperty(value = "排序优先级", required = true)
    @NotNull(message = "必须提交排序优先级")
    private Integer sort;

    @ApiModelProperty(value = "商品图片", required = true)
    @NotNull(message = "必须提交商品图片")
    private String url;


    private Integer saleCount;



}
